<el-form ref="form" :model="form" :rules="rules" label-width="120px">
    <el-row :gutter="10">
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="配件编号" prop="MMRS004">
                <el-input clearable v-model="form.MMRS004" :disabled="!isAdd" readOnly @clear="clearMmrs004">
                    <i v-show="isAdd" class="el-icon-search el-input__icon" @click="openGwam" slot="suffix"></i>
                </el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="品名" prop="GWAML003">
                <el-input v-model="form.GWAML003" readOnly>
                </el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="规格" prop="GWAML004">
                <el-input v-model="form.GWAML004" readOnly></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="仓库" prop="MMRS001">
                <el-input clearable v-model="form.MMRS001" :disabled="!isAdd" readOnly @clear="clearMmrs001">
                    <i v-show="isAdd" class="el-icon-search el-input__icon" @click="openGwat" slot="suffix"></i>
                </el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="库位" prop="MMRS002">
                <el-input v-model="form.MMRS002" readOnly></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="归属组织" prop="MMRS003">
                <el-input v-model="form.MMRS003_NAME" readOnly></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="批序号" prop="MMRS005">
                <el-input v-model="form.MMRS005" :readOnly="!isAdd"></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="单位" prop="MMRS006">
                <el-select clearable v-model="form.MMRS006" size="small" placeholder="请选择单位" :disabled="!isAdd">
                    <el-option v-for="item in selectOptions.gwabList"
                               :key="item.GWAB001"
                               :label="item.GWAB001 + ' ' + item.GWABL003"
                               :value="item.GWAB001">
                    </el-option>
                </el-select>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="数量" >
                <el-input v-model="form.MMRS008" ></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="安全库存量" prop="MMRS011">
                <el-input v-model="form.MMRS011" ></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="标准单价" >
                <el-input v-model="form.MMRS009" ></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="是否需要回收" prop="MMRS010">
                <el-select clearable v-model="form.MMRS010">
                    <el-option v-for="item in selectOptions.sys_1_0" :label="item.value" :value="item.code"></el-option>
                </el-select>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="有效" prop="MMRSACTI">
                <el-select clearable v-model="form.MMRSACTI">
                    <el-option v-for="item in selectOptions.sys_y_n" :label="item.value" :value="item.code"></el-option>
                </el-select>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
            <el-form-item label="有效日期" prop="MMRS007">
                <el-date-picker
                        v-model="form.MMRS007"
                        type="date"
                        value-format="yyyy-MM-dd"
                        style="width: 100%;">
                </el-date-picker>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
            <el-form-item label="备注" >
                <el-input type="textarea" v-model="form.MMRS012"></el-input>
            </el-form-item>
        </el-col>
        <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" style="text-align: right">
            <el-button icon="icon iconfont icon-23" size="mini" @click="cancle">关闭</el-button>
            <el-button v-show="!isDetail" type="warning" icon="icon iconfont icon-21" size="mini" @click="save">保存</el-button>
        </el-col>
    </el-row>
</el-form>
<script>
    require(["pc/crm/base/gwai680_edit"], $.noop);
</script>
